﻿<%@ Page Title="Email Delivery Report" Language="C#" MasterPageFile="~/masterpage.master"
	AutoEventWireup="true" CodeFile="EmailDeliveryReport.aspx.cs" Inherits="EmailDeliveryReport" %>

<%@ Register Src="ucLetters.ascx" TagName="ucLetters" TagPrefix="uc2" %>
<%@ Register Assembly="Telerik.Web.UI" Namespace="Telerik.Web.UI" TagPrefix="telerik" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
	<link rel="stylesheet" type="text/css" href="css/admin.css" />
	<script language="javascript" type="text/javascript">
	    var controldivname = 'ctl00_ContentPlaceHolder1_rgEmailDeliveryReport';
	</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
	<table width="95%">
		<tr>
			<td colspan="2">
				<div class="wrap4">
					<div class="abcd">
						<table width="100%" cellspacing="0">
							<tr>
								<td valign="middle">
									<label style="float: left">
										Date Range:</label>
								</td>
								<td valign="middle" align="left" width="100">
									<telerik:RadDatePicker ID="radDP_StartDate" runat="server" ZIndex="30001" Culture="en-US"
										Width="100%">
										<DatePopupButton ImageUrl="~/Images/calendar.jpg" HoverImageUrl="~/Images/calendar.jpg" />
									</telerik:RadDatePicker>
								</td>
								<td valign="middle" align="center" width="20">
									-
								</td>
								<td valign="middle" align="center" width="100">
									<telerik:RadDatePicker ID="radDP_EndDate" runat="server" ZIndex="30001" Culture="en-US"
										Width="100%">
										<DatePopupButton ImageUrl="~/Images/calendar.jpg" HoverImageUrl="~/Images/calendar.jpg" />
									</telerik:RadDatePicker>
								</td>
								<td valign="middle">
									<asp:Label ID="Label2" runat="server" Text="Section:"></asp:Label>
									<asp:DropDownList ID="dropLstSection" runat="server" Width="120" style="padding:3px;">
										<asp:ListItem>Select a Section</asp:ListItem>
									</asp:DropDownList>
									<asp:ImageButton ID="btnGo" runat="server" ImageUrl="images/go_button2.png" Text="Search"
										Style="height: 17px; vertical-align: middle;" OnClick="btnGo_Click" />
								</td>
								<td align="right" valign="middle">
									<asp:ImageButton ImageUrl="Images/excel_icon2.png" ID="lbExport" runat="server" OnClick="lbExport_Click"
										ToolTip="Export to Excel"></asp:ImageButton>
								</td>
							</tr>
						</table>
					</div>
				</div>
			</td>
		</tr>
	</table>
	<table style="width: 900px;">
		<tr>
			<td align="center">
				<telerik:RadScriptManager ID="RadScriptManager1" runat="server">
				</telerik:RadScriptManager>
				<telerik:RadAjaxManager runat="server" ID="RadAjaxManager1">
					<AjaxSettings>
						<telerik:AjaxSetting AjaxControlID="rgEmailDeliveryReport">
							<UpdatedControls>
								<telerik:AjaxUpdatedControl ControlID="rgEmailDeliveryReport" />
							</UpdatedControls>
						</telerik:AjaxSetting>
					</AjaxSettings>
				</telerik:RadAjaxManager>
				<telerik:RadGrid runat="server" ID="rgEmailDeliveryReport" Width="900px" AllowPaging="True"
					AllowSorting="True" PageSize="20" AutoGenerateColumns="False" OnNeedDataSource="rgEmailDeliveryReport_NeedDataSource"
					onpageindexchanged="radGrid_PageIndexChanged" 
					onpagesizechanged="radGrid_PageSizeChanged" GridLines="Horizontal" onitemcreated="rgEmailDeliveryReport_ItemCreated">
					<ClientSettings>
						<Scrolling AllowScroll="True" SaveScrollPosition="true" UseStaticHeaders="True">
						</Scrolling>
					</ClientSettings>
					<HeaderStyle BackColor="#060606" Font-Bold="True" Height="15px" Wrap="True" Font-Size="9"
						HorizontalAlign="Center" />
					<ItemStyle BackColor="Silver" />
					<AlternatingItemStyle BackColor="LightGray" />
					<MasterTableView Width="100%">
						<Columns>
							<telerik:GridHyperLinkColumn DataNavigateUrlFields="DATE_SENT" UniqueName="DATE_SENT"
								DataNavigateUrlFormatString="EmailDeliveryDetailsReport.aspx?d={0:yyyy-MM-dd}&s=all"
								HeaderText="Delivery Date" DataTextField="DATE_SENT" DataType="System.DateTime"
								DataTextFormatString="{0:MM/dd/yy}" ItemStyle-Width="225" HeaderStyle-Width="225"
								ItemStyle-HorizontalAlign="Center">
							</telerik:GridHyperLinkColumn>
							<telerik:GridHyperLinkColumn DataNavigateUrlFields="DATE_SENT" UniqueName="TOTALS_NUMBER_OF_EMAILS"
								DataNavigateUrlFormatString="EmailDeliveryDetailsReport.aspx?d={0:yyyy-MM-dd}&s=all"
								HeaderText="Total Number of Emails" DataTextField="TOTALS_NUMBER_OF_EMAILS" ItemStyle-Width="225"
								HeaderStyle-Width="225" ItemStyle-HorizontalAlign="Center">
							</telerik:GridHyperLinkColumn>
							<telerik:GridHyperLinkColumn DataNavigateUrlFields="DATE_SENT" UniqueName="DELIVERED"
								DataNavigateUrlFormatString="EmailDeliveryDetailsReport.aspx?d={0:yyyy-MM-dd}&s=1"
								HeaderText="Delivered" DataTextField="DELIVERED" ItemStyle-Width="225" HeaderStyle-Width="225"
								ItemStyle-HorizontalAlign="Center">
							</telerik:GridHyperLinkColumn>
							<telerik:GridHyperLinkColumn DataNavigateUrlFields="DATE_SENT" UniqueName="FAILED"
								DataNavigateUrlFormatString="EmailDeliveryDetailsReport.aspx?d={0:yyyy-MM-dd}&s=0"
								HeaderText="Failed" DataTextField="FAILED" ItemStyle-Width="225" HeaderStyle-Width="225"
								ItemStyle-HorizontalAlign="Center">
							</telerik:GridHyperLinkColumn>
						</Columns>
						<PagerStyle Mode="NextPrevNumericAndAdvanced" />
					</MasterTableView>
				</telerik:RadGrid>
			</td>
		</tr>
	</table>
</asp:Content>
